import 'package:flutter/material.dart';
import 'package:google_fonts/google_fonts.dart';

class GuildFrame extends StatelessWidget {
  final String icon;
  final String description1;
  final String description2;
  final Function? press;
  const GuildFrame({
    Key? key,
    required this.icon,
    required this.description1,
    required this.description2,
    required this.press,
  });

  @override
  Widget build(BuildContext context) {
    return SafeArea(
        child: Padding(
            padding: EdgeInsets.symmetric(vertical: 20.0, horizontal: 15.0),
            child: Column(
                crossAxisAlignment: CrossAxisAlignment.start,
                children: [
                  Row(
                    mainAxisAlignment: MainAxisAlignment.end,
                    children: [
                      GestureDetector(
                        onTap: press as void Function()?,
                        child: Container(
                          // margin: EdgeInsets.all(6.0),
                          width: 60,
                          height: 60,
                          decoration: BoxDecoration(
                            borderRadius: BorderRadius.circular(8),
                            image: DecorationImage(
                              image: AssetImage(icon),
                              fit: BoxFit.cover,
                            ),
                          ),
                        ),
                      ),

                    ],
                  ),
                  Spacer(),
                  Text(description1,
                      textAlign:TextAlign.left,
                      style: TextStyle(color: Colors.white,fontSize: 24,fontFamily: 'Galada',decoration: TextDecoration.none)),
                  SizedBox(height: 16),
                  Text(description2,
                      textAlign:TextAlign.left,
                      style: TextStyle(color: Colors.white,fontSize: 24,fontFamily: 'Galada',decoration: TextDecoration.none)),
                  SizedBox(height: 50),
                ]
            )
        )
    );
  }
}